home *** CD-ROM | disk | FTP | other *** search
/ System Booster / System Booster.iso / SYS / s / MakeNumber.tked < prev    next >
Text File  |  1996-09-26  |  823b  |  43 lines

  1. /** --------------------------------------------
  2.  ** ARexx program number all the lines of a text
  3.  ** --------------------------------------------
  4.  ** AREXX-Programm, das alle Zeilen nummeriert
  5.  ** --------------------------------------------
  6.  **
  7.  ** © Tom Kroener 1992
  8.  **/
  9.  
  10.  
  11. options results
  12.  
  13. address 'TKEd.1'        /* Name of TKEd's port */
  14.  
  15. SIGNAL ON BREAK_C
  16. LastLine            /* Get number of the last line in a text */
  17. x=result
  18.  
  19. BeginOfFile         /* Go to the top of the text */
  20.  
  21. GetLineNr           /* Get linenumber */
  22. y=result
  23.  
  24. do while y < x
  25.   BeginOfLine
  26.  
  27.   WriteString y     /* Write number */
  28.   WriteString ": "  /* Write ': '   */
  29.  
  30.   Cursor "DOWN"
  31.  
  32.   GetLineNr         /* Get linenumber */
  33.   y=result
  34.  
  35. end
  36.  
  37. BeginOfLine
  38.  
  39. WriteString y     /* Write number */
  40. WriteString ": "  /* Write ': '   */
  41.  
  42. BREAK_C:
  43.